Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Populate backend.configuration_dict from target_info endpoint #666

Merged
merged 26 commits into from
Aug 7, 2023

Conversation

vtomole
Copy link
Member

@vtomole vtomole commented Jul 29, 2023

Part of #342

@@ -462,17 +462,6 @@ def process_dfe(self, ids: List[str]) -> float:
"""
return self._client.process_dfe(ids)

def target_info(self, target: str) -> Dict[str, Any]:
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is deleted cause it's not how qiskit users are supposed to be getting target info. They should be using backend.configuration


def test_default_options() -> None:
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unnecessary test: Don't affect coverage with it's removal and doesn't look like a regression test.

@vtomole
Copy link
Member Author

vtomole commented Aug 2, 2023

Notebooks check won't pass until a new version of server is released.

@vtomole vtomole marked this pull request as ready for review August 2, 2023 20:27
Copy link
Contributor

@bharat-thotakura bharat-thotakura left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Partial review

Copy link
Contributor

@bharat-thotakura bharat-thotakura left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM apart from some very minor docstring nits (and #666 (comment) if it's relevant)

qiskit-superstaq/qiskit_superstaq/conftest.py Outdated Show resolved Hide resolved
qiskit-superstaq/qiskit_superstaq/conftest.py Outdated Show resolved Hide resolved
qiskit-superstaq/qiskit_superstaq/conftest.py Outdated Show resolved Hide resolved
qiskit-superstaq/qiskit_superstaq/conftest.py Outdated Show resolved Hide resolved
qiskit-superstaq/qiskit_superstaq/conftest.py Outdated Show resolved Hide resolved
qiskit-superstaq/qiskit_superstaq/conftest.py Outdated Show resolved Hide resolved
vtomole and others added 3 commits August 7, 2023 10:34
Co-authored-by: Bharath Thotakura <113555655+bharat-thotakura@users.noreply.github.com>
Co-authored-by: Bharath Thotakura <113555655+bharat-thotakura@users.noreply.github.com>
Co-authored-by: Bharath Thotakura <113555655+bharat-thotakura@users.noreply.github.com>
vtomole and others added 7 commits August 7, 2023 10:35
Co-authored-by: Bharath Thotakura <113555655+bharat-thotakura@users.noreply.github.com>
Co-authored-by: Bharath Thotakura <113555655+bharat-thotakura@users.noreply.github.com>
Co-authored-by: Bharath Thotakura <113555655+bharat-thotakura@users.noreply.github.com>
@vtomole
Copy link
Member Author

vtomole commented Aug 7, 2023

@bharat-thotakura I did need to apply your suggestion for the other keys though: #678. Just pushed a commit to handle undefined keys. Please take a look.

Copy link
Contributor

@bharat-thotakura bharat-thotakura left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tested the changes locally and it seems fine to me. Though, I did notice that qss.SuperstaqProvider().get_backend(<target>).configuration_dict yields a couple of duplicate information. Namely, 'backend_name' <-> 'target' and 'n_qubits' <-> 'num_qubits' list the same thing. I think this is because of self.configuration_dict.update(target_info), so it may be worth dropping the duplicate key info.

@vtomole
Copy link
Member Author

vtomole commented Aug 7, 2023

Good catch. I've removed them from the final dict.

@bharat-thotakura
Copy link
Contributor

@vtomole No other changes from me 👍

@vtomole vtomole merged commit 7d0e243 into main Aug 7, 2023
15 checks passed
@vtomole vtomole deleted the populate_backend_config branch August 7, 2023 19:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants